package com.hang.mongoEntity;

import lombok.Data;
import lombok.ToString;
import org.springframework.data.mongodb.core.index.Indexed;
import org.springframework.data.mongodb.core.mapping.Document;
import org.springframework.data.mongodb.core.mapping.Field;

@Document("BugEntity")
@Data
@ToString
public class BugEntity {
    @Indexed(unique = true)
    @Field("_id")
    private String mongoId;

    @Field("content")
    private String content;

    public BugEntity() {
    }

    public BugEntity(String mongoId, String content) {
        this.mongoId = mongoId;
        this.content = content;
    }
}
